import {ref, watch} from 'vue'
export default function useTitle(titleValue){
    // 定义ref的引入数据
    const title = ref(titleValue)

    watch(title, (newValue)=>{
        document.title = newValue
    },{
        immediate:true
    })
    return title
}